﻿using System;
using System.Runtime.Serialization;

namespace ModelLayer
{
    [DataContract]
    public class PartRoute
    {
        public PartRoute()
        {
        }

        public PartRouteStatusEnum PartRouteStatus;

        public PartRoute(Station locationEnd, Station locationStart)
        {
            LocationEnd = locationEnd;
            LocationStart = locationStart;
        }

        [DataMember]
        public long Id
        {
            get;
            set;
        }

        [DataMember]
        public double Distance
        {
            get;
            set;
        }

        [DataMember]
        public TimeSpan Time
        {
            get;
            set;
        }

        [DataMember]
        public Station LocationEnd
        {
            get;
            set;
        }

        [DataMember]
        public Station LocationStart
        {
            get;
            set;
        }
    }

    [DataContract(Name = "PartRouteStatus")]
    public enum PartRouteStatusEnum
    {
        [EnumMember]
        Reserved,
        [EnumMember]
        Complete
    }
}